﻿using FreeSql.DatabaseModel;using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using System.Reflection;
using System.Threading.Tasks;
using Newtonsoft.Json;
using FreeSql.DataAnnotations;

namespace Simple.Repository.SimpleEntitys {

	/// <summary>
	/// 照护记录
	/// </summary>
	[JsonObject(MemberSerialization.OptIn), Table(Name = "elderly_care_record", DisableSyncStructure = true)]
	public partial class ElderlyCareRecord {

		/// <summary>
		/// 主键Id
		/// </summary>
		[JsonProperty, Column(Name = "id", DbType = "bigint", IsPrimary = true, IsIdentity = true)]
		public long Id { get; set; }

		/// <summary>
		/// 公司Id
		/// </summary>
		[JsonProperty, Column(Name = "company_id", DbType = "bigint")]
		public long CompanyId { get; set; }

		/// <summary>
		/// 长者Id
		/// </summary>
		[JsonProperty, Column(Name = "elderly_id", DbType = "bigint")]
		public long ElderlyId { get; set; }

		/// <summary>
		/// 照护项目分类Id
		/// </summary>
		[JsonProperty, Column(Name = "categorize_id", DbType = "bigint")]
		public long CategorizeId { get; set; }

		/// <summary>
		/// 照护项目Id
		/// </summary>
		[JsonProperty, Column(Name = "care_mission_id", DbType = "bigint")]
		public long CareMissionId { get; set; }

		/// <summary>
		/// 照护项目名称
		/// </summary>
		[JsonProperty, Column(Name = "name", IsNullable = false)]
		public string Name { get; set; }

		/// <summary>
		/// 照护项目描述、注意事项
		/// </summary>
		[JsonProperty, Column(Name = "description", StringLength = -1)]
		public string Description { get; set; }

		/// <summary>
		/// 是否每日照护任务：0=否、1=是
		/// </summary>
		[JsonProperty, Column(Name = "is_daily_mission", DbType = "int")]
		public int IsDailyMission { get; set; } = 1;

		/// <summary>
		/// 每日照护任务：建议开始时间（HH:mm）
		/// </summary>
		[JsonProperty, Column(Name = "daily_mission_start_time", StringLength = 5)]
		public string DailyMissionStartTime { get; set; }

		/// <summary>
		/// 每日照护任务：建议结束时间（HH:mm）
		/// </summary>
		[JsonProperty, Column(Name = "daily_mission_end_time", StringLength = 5)]
		public string DailyMissionEndTime { get; set; }

		/// <summary>
		/// 每日照护任务：建议结束时间（HHmm）
		/// </summary>
		[JsonProperty, Column(Name = "daily_mission_end_time_value", DbType = "int")]
		public int? DailyMissionEndTimeValue { get; set; }

		/// <summary>
		/// 每日照护任务：建议开始时间（HHmm）
		/// </summary>
		[JsonProperty, Column(Name = "daily_mission_start_time_value", DbType = "int")]
		public int? DailyMissionStartTimeValue { get; set; }

		/// <summary>
		/// 每日照护任务：建议执行次数
		/// </summary>
		[JsonProperty, Column(Name = "daily_mission_execution_count", DbType = "int")]
		public int? DailyMissionExecutionCount { get; set; }

		/// <summary>
		/// 是否需要拍照打卡：0=不需要、1=需要
		/// </summary>
		[JsonProperty, Column(Name = "is_take photos", DbType = "int")]
		public int? IsTakePhotos { get; set; }

		/// <summary>
		/// 创建时间
		/// </summary>
		[JsonProperty, Column(Name = "create_time", DbType = "datetime")]
		public DateTime CreateTime { get; set; }

		/// <summary>
		/// 创建人
		/// </summary>
		[JsonProperty, Column(Name = "create_by", DbType = "bigint")]
		public long CreateBy { get; set; }

		/// <summary>
		/// 更新时间
		/// </summary>
		[JsonProperty, Column(Name = "update_time", DbType = "datetime")]
		public DateTime UpdateTime { get; set; }

		/// <summary>
		/// 更新人
		/// </summary>
		[JsonProperty, Column(Name = "update_by", DbType = "bigint")]
		public long UpdateBy { get; set; }

		/// <summary>
		/// 排序
		/// </summary>
		[JsonProperty, Column(Name = "sort", DbType = "int")]
		public int? Sort { get; set; }

		/// <summary>
		/// 照护项目执行护理员工列表
		/// </summary>
		[JsonProperty, Column(Name = "care_worker_employee_ids", StringLength = -1)]
		public string CareWorkerEmployeeIds { get; set; }

		/// <summary>
		/// 是否删除：0=未删除、1=已删除
		/// </summary>
		[JsonProperty, Column(Name = "is_delete", DbType = "int")]
		public int IsDelete { get; set; }

		/// <summary>
		/// 长者照护计划项目Id
		/// </summary>
		[JsonProperty, Column(Name = "elderly_care_mission_id", DbType = "bigint")]
		public long ElderlyCareMissionId { get; set; }

		/// <summary>
		/// 完成时间
		/// </summary>
		[JsonProperty, Column(Name = "completion_time", DbType = "datetime")]
		public DateTime CompletionTime { get; set; }

		/// <summary>
		/// 是否在建议时间内完成：0=不是、1=是
		/// </summary>
		[JsonProperty, Column(Name = "completion_at_specified_time", DbType = "int")]
		public int CompletionAtSpecifiedTime { get; set; }

		/// <summary>
		/// 完成人
		/// </summary>
		[JsonProperty, Column(Name = "completion_by", DbType = "bigint")]
		public long CompletionBy { get; set; }

		/// <summary>
		/// 记录内容
		/// </summary>
		[JsonProperty, Column(Name = "record_content", StringLength = -1)]
		public string RecordContent { get; set; }

		/// <summary>
		/// 照护记录媒体内容
		/// </summary>
		[JsonProperty, Column(Name = "elderly_care_record_media_json", StringLength = -1)]
		public string ElderlyCareRecordMediaJson { get; set; }

	}

}
